(load-plugin "popup")
(load-plugin "auto-complete")

(require 'auto-complete-config)
(ac-config-default)
(add-to-list 'ac-dictionary-directories "~/.emacs.d/auto-complete-dict")
(global-auto-complete-mode t)

;; 使用Ctrl+enter按键触发自动补全 
(ac-set-trigger-key "TAB")
(define-key ac-mode-map (kbd "M-/") 'auto-complete)
(define-key ac-mode-map  [(control return)] 'auto-complete)
(define-key ac-completing-map (kbd "C-n") 'ac-next)
(define-key ac-completing-map (kbd "C-p") 'ac-previous)

(provide 'mod-auto-complete)
